package com.atldy.commerce.feign.hystrix;

import cn.hutool.core.collection.ListUtil;
import com.atldy.commerce.commence.TableId;
import com.atldy.commerce.commence.goods.SimpleGoodsInfo;
import com.atldy.commerce.feign.SecureGoodsClient;
import com.atldy.commerce.vo.CommonResponse;
import lombok.extern.slf4j.Slf4j;
import org.springframework.stereotype.Component;

import java.util.List;

/**
 * <h2> TODO </h2>
 *
 * @Author: li-dong-yang
 * @CreateTime: 2021-11-04 23:13
 */
@Slf4j
@Component
public class SecureGoodsHystrix implements SecureGoodsClient {


    @Override
    public CommonResponse<List<SimpleGoodsInfo>> getSimpleGoodsInfos(TableId tableId) {
        log.error("get response getSimpleGoodsInfos fail ");
        return new CommonResponse<List<SimpleGoodsInfo>>(-1
                , "get response getSimpleGoodsInfos fail",
                ListUtil.empty());
    }
}